{% load i18n %}
{% if reactions %}
<a name="comments"></a>
<a name="discussion"></a>
<div class="comments-title">
    <h4> {% trans "Discussion" %}</h4>
</div>

{% for reaction in reactions %}

{% if reaction.author%}
	{% ifequal reaction.author reaction.weblog.author%}
	<div class='author_comment' style="padding-left:{% widthratio reaction.reply_depth 10 600 %}">
	{% else %}
	<div class='{% cycle comment,comment1 %}' style="margin-left:{% widthratio reaction.reply_depth 10 600 %}">
	{% endifequal %}
{% else %}
	<div class='{% cycle comment,comment1 %}' style="margin-left:{% widthratio reaction.reply_depth 10 600 %}">		
{% endif %}
	    <div> 
			<a name="comment-{{reaction.key.id}}"></a>
			{% if reaction.authorWebsite %}
	        <a href="{{reaction.authorWebsite|url_fix}}">
	        {% endif%}
	        <b>{%if not reaction.author %}{{reaction.user}}{%else%}{{reaction.author.email|email_username}}{% endif %}</b> |
	        {% if reaction.authorWebsite %}
	        </a>
	        {% endif%}
	        {{reaction.date|timezone:BLOG.time_zone_offset|date:"Y-m-d H:i"}}
	    </div>
		
	    <div class="post-body">
	        <img height="32" width="32" class="avatar" src="{%if not reaction.author %}{{reaction.authorEmail|gravatar}}{%else%}{{reaction.author.email|gravatar}}{% endif %}"/>
	        <div>{{reaction.content}}</div>
	    </div>
		
	    <div class="post-footer">		
	            <span class='comment-timestamp'>
					:<a href='javascript:replyToComment("{{reaction.key.id}}")'>{% trans "reply" %}</a>:
	                {% if user_is_admin %}
					:<a href='/edit/comment/{{reaction.key.id}}'>{% trans "edit" %}</a>:
	                :<a href='/delete/comment/{{reaction.key.id}}'>{% trans "delete" %}</a>:
	                {% endif %}
	
	                {% ifnotequal reaction.lastModifiedDate Null %}
	                {% blocktrans with reaction.lastModifiedDate as react_lastModData and reaction.lastModifiedBy as react_lastModBy %}Edited at {{react_lastModData}} by {{react_lastModBy}}.{% endblocktrans %}
	                {% endifnotequal %}
	            </span>
	    </div>
	</div>
{% endfor %}
{% endif %}